<!DOCTYPE html>

<html lang="en">
<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width">
	<title>Common Modules Source: constants.js</title>

	<!--[if lt IE 9]>
	<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
	<![endif]-->
	<link type="text/css" rel="stylesheet" href="styles/sunlight.default.css">

	<link type="text/css" rel="stylesheet" href="styles/site.simplex.css">

</head>

<body>

<div class="navbar navbar-default navbar-fixed-top navbar-inverse">
<div class="container">
	<div class="navbar-header">
		<a class="navbar-brand" href="index.html">Common Modules</a>
		<button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation">
			<span class="icon-bar"></span>
			<span class="icon-bar"></span>
			<span class="icon-bar"></span>
        </button>
	</div>
	<div class="navbar-collapse collapse" id="topNavigation">
		<ul class="nav navbar-nav">
			
			<li class="dropdown">
				<a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a>
				<ul class="dropdown-menu ">
					<li><a href="Base.html">Base</a></li><li><a href="Event.html">Event</a></li><li><a href="Html.html">Html</a></li><li><a href="Internal.html">Internal</a></li><li><a href="ol.Overlay.Popup.html">ol.Overlay.Popup</a></li>
				</ul>
			</li>
			
			<li class="dropdown">
				<a href="global.html" class="dropdown-toggle" data-toggle="dropdown">Global<b class="caret"></b></a>
				<ul class="dropdown-menu ">
					<li><a href="global.html#addClass">addClass</a></li><li><a href="global.html#addListener">addListener</a></li><li><a href="global.html#arrayRemove">arrayRemove</a></li><li><a href="global.html#clear">clear</a></li><li><a href="global.html#create">create</a></li><li><a href="global.html#createHidden">createHidden</a></li><li><a href="global.html#empty">empty</a></li><li><a href="global.html#EventType">EventType</a></li><li><a href="global.html#findListener">findListener</a></li><li><a href="global.html#firstUpperToCase">firstUpperToCase</a></li><li><a href="global.html#get">get</a></li><li><a href="global.html#getChildByTagName">getChildByTagName</a></li><li><a href="global.html#getClass">getClass</a></li><li><a href="global.html#getDomEventKey">getDomEventKey</a></li><li><a href="global.html#getElementsByClassName">getElementsByClassName</a></li><li><a href="global.html#getListeners">getListeners</a></li><li><a href="global.html#getrandom">getrandom</a></li><li><a href="global.html#getStyle">getStyle</a></li><li><a href="global.html#getuuid">getuuid</a></li><li><a href="global.html#hasClass">hasClass</a></li><li><a href="global.html#isObject">isObject</a></li><li><a href="global.html#isString">isString</a></li><li><a href="global.html#layerConfigDefautls">layerConfigDefautls</a></li><li><a href="global.html#listen">listen</a></li><li><a href="global.html#listenOnce">listenOnce</a></li><li><a href="global.html#logo">logo</a></li><li><a href="global.html#OL_Style_Type">OL_Style_Type</a></li><li><a href="global.html#remove">remove</a></li><li><a href="global.html#removeClass">removeClass</a></li><li><a href="global.html#removeListener">removeListener</a></li><li><a href="global.html#removeListeners">removeListeners</a></li><li><a href="global.html#setClass">setClass</a></li><li><a href="global.html#splitWords">splitWords</a></li><li><a href="global.html#stamp">stamp</a></li><li><a href="global.html#toBack">toBack</a></li><li><a href="global.html#toFront">toFront</a></li><li><a href="global.html#trim">trim</a></li><li><a href="global.html#unListen">unListen</a></li><li><a href="global.html#unlistenAll">unlistenAll</a></li><li><a href="global.html#unListenByKey">unListenByKey</a></li><li><a href="global.html#upperFirstChart">upperFirstChart</a></li>
				</ul>
			</li>
			
		</ul>
        
            <div class="col-sm-3 col-md-3">
                <form class="navbar-form" role="search">
                    <div class="input-group">
                        <input type="text" class="form-control" placeholder="Search" name="q" id="search-input">
                        <div class="input-group-btn">
                            <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button>
                        </div>
                    </div>
                </form>
            </div>
        
	</div>

</div>
</div>


<div class="container" id="toc-content">
<div class="row">

	
	<div class="col-md-12">
	
		<div id="main">
			

		<h1 class="page-title">Source: constants.js</h1>
    
<section>
    <article>
        <pre
            class="sunlight-highlight-javascript linenums">/*
 * 静态常量
 * @Author: liuyang
 * @Date: 2017-09-17 11:02:50
 * @Last Modified by: liuyang
 * @Last Modified time: 2017-10-12 08:30:08
 */
export const x_PI = 3.14159265358979324 * 3000.0 / 180.0;
export const PI = 3.1415926535897932384626; // PI
export const a = 6378245.0; // 北京54坐标系长半轴a=6378245m
export const ee = 0.00669342162296594323;
import _ol from '../node_modules/openlayers'
import _projzh from '../node_modules/projzh'
export const BASE_CLASS_NAME = {
    CLASS_HIDDEN: 'gmap-hidden',
    CLASS_SELECTABLE: 'gmap-selectable',
    CLASS_UNSELECTABLE: 'gmap-unselectable',
    CLASS_CONTROL: 'gmap-control'
  }
export const ol = _ol;
export const projzh = _projzh;

/**
 * 图层默认配置项
 */
export const layerConfigDefautls = {
    tileType: 0,
    isVisible: true,
    isDefault:true,
    layerName: '',
    crossOrigin: 'Anonymous',
    alias:'',
    attribution: {
      url: 'http://www.keepsoft.net/',
      title: '贵仁科技',
      messages: '版权所有'
  }
};

export const EVENT_TYPE = { // 事件类型
    LOAD_MAP_SUCCESS: 'loadMapSuccess', // 地图初始化成功事件
    CLICK: 'click', // 点击事件
    DBCLICK: 'dblclick', // 双击事件
    SINGLECLICK: 'singleclick', // 单击事件
    MOVESTART: 'movestart', // 地图开始移动事件
    MOVEEND: 'moveend', // 地图结束移动事件
    POINTERDRAG: 'pointerdrag', // 拖拽事件
    POINTERMOVE: 'pointermove', // 移动事件
    PRECOMPOSE: 'precompose', // 开始渲染之前
    POSTRENDER: 'postrender', // 开始渲染
    POSTCOMPOSE: 'postcompose', // 渲染完成
    PROPERTYCHANGE: 'propertychange', // 属性变化
    CHANGE: 'change', // change
    CHANGELAYERGROUP: 'change:layerGroup', // 图层组变化
    CHANGESIZE: 'change:size', // 大小变化
    CHANGETARGET: 'change:target', // target变化
    CHANGEVIEW: 'change:view', // 视图变化
    FEATUREONMOUSEOVER: 'feature:onmouseover', // 要素的鼠标移入事件
    FEATUREONMOUSEOUT: 'feature:onmouseout', // 要素的鼠标移出事件
    FEATUREONMOUSEDOWN: 'feature:onmousedown', // 要素鼠标按下
    FEATUREONMOUSEUP: 'feature:onmouseup', // 要素鼠标抬起
    FEATUREONMOVE: 'feature:onmove', // 要素移动
    FEATUREONSELECT: 'feature:onselect', // 要素选中事件
    FEATUREONDISSELECT: 'feature:ondisselect', // 要素取消选中事件


  }

export const INTERNAL_KEY = { // 自定义键值
    SELECTABLE: 'selectable', // 要素是否可以被选择
    MOVEABLE: 'moveable' // 要素是否可以被移动
  }


/**
 * ol 的常用style类型
 */
export const OL_Style_Type={
  'fill':'ol.style.Fill',
  'text':'ol.style.Text',
  'circle':'ol.style.Circle',
  'stroke':'ol.style.Stroke',
  'icon':'ol.style.Icon'
}</pre>
    </article>
</section>





		</div>
	</div>

	<div class="clearfix"></div>

	

</div>
</div>


    <div class="modal fade" id="searchResults">
      <div class="modal-dialog">
        <div class="modal-content">
          <div class="modal-header">
            <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
            <h4 class="modal-title">Search results</h4>
          </div>
          <div class="modal-body"></div>
          <div class="modal-footer">
            <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
          </div>
        </div><!-- /.modal-content -->
      </div><!-- /.modal-dialog -->
    </div>


<footer>


	<span class="copyright">
	https://lzw.me.
	</span>

<span class="jsdoc-message">
	Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.5</a>
	
		on Sun Aug 12th 2018
	
	using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>.
</span>
</footer>

<script src="scripts/docstrap.lib.js"></script>
<script src="scripts/toc.js"></script>

    <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script>


<script>
$( function () {
	$( "[id*='$']" ).each( function () {
		var $this = $( this );

		$this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) );
	} );

	$( ".tutorial-section pre, .readme-section pre, pre.prettyprint.source" ).each( function () {
		var $this = $( this );

		var example = $this.find( "code" );
		exampleText = example.html();
		var lang = /{@lang (.*?)}/.exec( exampleText );
		if ( lang && lang[1] ) {
			exampleText = exampleText.replace( lang[0], "" );
			example.html( exampleText );
			lang = lang[1];
		} else {
			var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/);
			lang = langClassMatch ? langClassMatch[1] : "javascript";
		}

		if ( lang ) {

			$this
			.addClass( "sunlight-highlight-" + lang )
			.addClass( "linenums" )
			.html( example.html() );

		}
	} );

	Sunlight.highlightAll( {
		lineNumbers : true,
		showMenu : true,
		enableDoclinks : true
	} );

	$.catchAnchorLinks( {
        navbarOffset: 10
	} );
	$( "#toc" ).toc( {
		anchorName  : function ( i, heading, prefix ) {
			return $( heading ).attr( "id" ) || ( prefix + i );
		},
		selectors   : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4",
		showAndHide : false,
		smoothScrolling: true
	} );

	$( "#main span[id^='toc']" ).addClass( "toc-shim" );
	$( '.dropdown-toggle' ).dropdown();

    $( "table" ).each( function () {
      var $this = $( this );
      $this.addClass('table');
    } );

} );
</script>



<!--Navigation and Symbol Display-->


<!--Google Analytics-->



    <script type="text/javascript">
        $(document).ready(function() {
            SearcherDisplay.init();
        });
    </script>


</body>
</html>
